#include "maze.h"

int mg[M+2][N+2] =
{
    {1,1,1,1,1,1,1,1,1,1},
    {1,0,0,1,0,0,0,1,0,1},
    {1,0,0,1,0,0,0,1,0,1},
    {1,0,0,0,0,1,1,0,0,1},
    {1,0,1,1,1,0,0,0,0,1},
    {1,0,0,0,1,0,0,0,0,1},
    {1,0,1,0,0,0,1,0,0,1},
    {1,0,1,1,1,0,1,1,0,1},
    {1,1,0,0,0,0,0,0,0,1},
    {1,1,1,1,1,1,1,1,1,1}};

void InitStack(SqStack *&s){
    s = (SqStack *)malloc(sizeof(SqStack));
    s->top = -1;
}
void ClearStack(SqStack *&s){
    free(s);
}
bool StackEmpty(SqStack *s){
    return s->top == -1;
}
bool Push(SqStack *&s, block e){
    if(s->top == MAXSIZE-1) return false;
    s->top++;
    s->st[s->top] = e;
    return true;
}
bool Pop(SqStack *&s, block &e){
    if(s->top==-1) return false;
    e = s->st[s->top];
    s->top--;
    return true;
}
int mgpath(int xi, int yi, int xe, int ye){
}
